//
//  WatchLiveTipView.m
//  LiveStar
//
//  Created by 漪珊 on 2017/1/5.
//  Copyright © 2017年 apple. All rights reserved.
//

#import "WatchLiveTipView.h"
#import "LiveListModel.h"

@implementation WatchLiveTipView
- (void)awakeFromNib {
    [super awakeFromNib];
    self.tipViewHeightConstraints.constant = 282*kScale;
    self.tipView.layer.contents = (__bridge id _Nullable)(kSET_IMAGE(@"cover_9")).CGImage;
    
    kButtonRadius(self.watchBtn, self.watchBtn.height/2);
}

- (void)setLivelistModel:(LiveListModel *)livelistModel {
    _livelistModel = livelistModel;
    self.priceLabel.text = KString(livelistModel.s_price);
    self.desc.text = [NSString stringWithFormat:@"观看直播将消耗您%@L币",livelistModel.s_price];
}

#pragma mark -- 关闭提示
- (IBAction)closeTip:(id)sender {//移除提示框
    [self.delegate closeTipView];
}

#pragma mark -- 观看直播/去购买芝麻
- (IBAction)tipFunctionClick:(id)sender {
    [self.delegate buyClickWithTipView:self LiveListModel:self.livelistModel];
}

@end
